package utn.frd.persistence;

import javax.jdo.JDOHelper;
import javax.jdo.PersistenceManagerFactory;

/**
 * Persistence Manager consumes a lot of resources on your instantiation, for this reason
 * we used a class with a static variable who contais the Persistence Manager Factory
 * instance available once it has been initialized.
 * 
 * It's responsible to do all related to the data connection.
 * @author Sergio
 *
 */

public final class PMF {
	private static final PersistenceManagerFactory pmfInstance = JDOHelper.getPersistenceManagerFactory("transactions-optional");

	private PMF() {}

	public static PersistenceManagerFactory get() {
		return pmfInstance;
	}
}
